export class ApiRequest {
    action: string;
    chainName?: string;
    body?: ApiRequestBody;
    callback?: string;
    constructor(action: string, chainName?: string, body?: ApiRequestBody, callback?: string) {
        this.action = action;
        this.chainName = chainName;
        this.body = body;
        this.callback = callback;
    }
}

export class ApiRequestBody {
    contractName: string;
    method: string;
    params: { [key: string]: string };

    constructor(contractName: string, method: string, params: { [key: string]: string }) {
        this.contractName = contractName;
        this.method = method;
        this.params = params;
    }
}